home *** CD-ROM | disk | FTP | other *** search
- Path: news.mindspring.com!usenet
- From: Danette & Murray Root <mroot@atl.mindspring.com>
- Newsgroups: comp.lang.c
- Subject: Re: A quick newbie question...hopefully...HELP!
- Date: Sat, 13 Apr 1996 02:08:05 -0400
- Organization: MindSpring Enterprises, Inc.
- Message-ID: <316F44C5.4324@atl.mindspring.com>
- References: <4kn8gk$6t1@info.evansville.net>
- NNTP-Posting-Host: user-168-121-127-88.dialup.mindspring.com
- Mime-Version: 1.0
- Content-Type: text/plain; charset=us-ascii
- Content-Transfer-Encoding: 7bit
- X-Mailer: Mozilla 2.01Gold (Win95; I)
-
- gilligan wrote:
- >
- > Hi!
- > I am just starting at C, and have a question...one of my problems is I
- > have to create a type of "Word Processor" where, regardless of number
- > of carriage returns or spaces, I have to cram as many words as
- > possible onto one line,
-
- ---- snip a lot because my newsreader will not let me reply with less new stuff than I quote ----
-
- Look at scanf() and family. You can do a lot of whitespace trimming, then use strtok() to remove the
- <cr>'s you don't want. Then strtok() again to put in the necessary <cr>'s.
-
- Don't forget a LOT of error-checking.
-